<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
    xmlns:s="http://jboss.com/products/seam/taglib"
    xmlns:ui="http://java.sun.com/jsf/facelets"
    xmlns:f="http://java.sun.com/jsf/core"
    xmlns:h="http://java.sun.com/jsf/html"
    xmlns:rich="http://richfaces.org/rich"
    template="layout/template.xhtml">

<ui:define name="body">

    <h:form id="invDevolucionSearch" styleClass="edit">

        <rich:simpleTogglePanel label="InvDevolucion Search Filter" switchType="ajax">

            <s:decorate template="layout/display.xhtml">
                <ui:define name="label">Dev observacion</ui:define>
                <h:inputText id="devObservacion" value="#{invDevolucionList.invDevolucion.devObservacion}"/>
            </s:decorate>


        </rich:simpleTogglePanel>

        <div class="actionButtons">
            <h:commandButton id="search" value="Search" action="/InvDevolucionList.xhtml"/>
            <s:button id="reset" value="Reset" includePageParams="false"/>
        </div>

    </h:form>

    <rich:panel>
        <f:facet name="header">InvDevolucion Search Results</f:facet>
    <div class="results" id="invDevolucionList">

    <h:outputText value="The invDevolucion search returned no results."
               rendered="#{empty invDevolucionList.resultList}"/>

    <rich:dataTable id="invDevolucionList"
                var="_invDevolucion"
              value="#{invDevolucionList.resultList}"
           rendered="#{not empty invDevolucionList.resultList}">
        <h:column>
            <f:facet name="header">
                <ui:include src="layout/sort.xhtml">
                    <ui:param name="entityList" value="#{invDevolucionList}"/>
                    <ui:param name="propertyLabel" value="Dev codigo"/>
                    <ui:param name="propertyPath" value="invDevolucion.devCodigo"/>
                </ui:include>
            </f:facet>
            <h:outputText value="#{_invDevolucion.devCodigo}"/>
        </h:column>
        <h:column>
            <f:facet name="header">
                <ui:include src="layout/sort.xhtml">
                    <ui:param name="entityList" value="#{invDevolucionList}"/>
                    <ui:param name="propertyLabel" value="De descuento"/>
                    <ui:param name="propertyPath" value="invDevolucion.deDescuento"/>
                </ui:include>
            </f:facet>
            <h:outputText value="#{_invDevolucion.deDescuento}">
                <f:convertNumber/>
            </h:outputText>
        </h:column>
        <h:column>
            <f:facet name="header">
                <ui:include src="layout/sort.xhtml">
                    <ui:param name="entityList" value="#{invDevolucionList}"/>
                    <ui:param name="propertyLabel" value="Dep codigo"/>
                    <ui:param name="propertyPath" value="invDevolucion.depCodigo"/>
                </ui:include>
            </f:facet>
            <h:outputText value="#{_invDevolucion.depCodigo}"/>
        </h:column>
        <h:column>
            <f:facet name="header">
                <ui:include src="layout/sort.xhtml">
                    <ui:param name="entityList" value="#{invDevolucionList}"/>
                    <ui:param name="propertyLabel" value="Dev codigo factura"/>
                    <ui:param name="propertyPath" value="invDevolucion.devCodigoFactura"/>
                </ui:include>
            </f:facet>
            <h:outputText value="#{_invDevolucion.devCodigoFactura}"/>
        </h:column>
        <h:column>
            <f:facet name="header">
                <ui:include src="layout/sort.xhtml">
                    <ui:param name="entityList" value="#{invDevolucionList}"/>
                    <ui:param name="propertyLabel" value="Dev fecha"/>
                    <ui:param name="propertyPath" value="invDevolucion.devFecha"/>
                </ui:include>
            </f:facet>
            <h:outputText value="#{_invDevolucion.devFecha}">
                <s:convertDateTime type="date" dateStyle="short"/>
            </h:outputText>
        </h:column>
        <h:column>
            <f:facet name="header">
                <ui:include src="layout/sort.xhtml">
                    <ui:param name="entityList" value="#{invDevolucionList}"/>
                    <ui:param name="propertyLabel" value="Dev iva"/>
                    <ui:param name="propertyPath" value="invDevolucion.devIva"/>
                </ui:include>
            </f:facet>
            <h:outputText value="#{_invDevolucion.devIva}">
                <f:convertNumber/>
            </h:outputText>
        </h:column>
        <h:column>
            <f:facet name="header">
                <ui:include src="layout/sort.xhtml">
                    <ui:param name="entityList" value="#{invDevolucionList}"/>
                    <ui:param name="propertyLabel" value="Dev observacion"/>
                    <ui:param name="propertyPath" value="invDevolucion.devObservacion"/>
                </ui:include>
            </f:facet>
            <h:outputText value="#{_invDevolucion.devObservacion}"/>
        </h:column>
        <h:column>
            <f:facet name="header">
                <ui:include src="layout/sort.xhtml">
                    <ui:param name="entityList" value="#{invDevolucionList}"/>
                    <ui:param name="propertyLabel" value="Subdepartamento subdep codigo"/>
                    <ui:param name="propertyPath" value="invDevolucion.subdepartamento.subdepCodigo"/>
                </ui:include>
            </f:facet>
            <h:outputText value="#{_invDevolucion.subdepartamento.subdepCodigo}"/>
        </h:column>
        <rich:column styleClass="action">
            <f:facet name="header">Action</f:facet>
            <s:link view="/#{empty from ? 'InvDevolucion' : from}.xhtml"
                   value="#{empty from ? 'View' : 'Select'}"
             propagation="#{empty from ? 'none' : 'default'}"
                      id="invDevolucion">
                <f:param name="invDevolucionDevCodigo"
                        value="#{_invDevolucion.devCodigo}"/>
            </s:link>
            #{' '}
            <s:link view="/InvDevolucionEdit.xhtml"
                   value="Edit"
             propagation="none"
                      id="invDevolucionEdit"
                rendered="#{empty from}">
                <f:param name="invDevolucionDevCodigo"
                        value="#{_invDevolucion.devCodigo}"/>
            </s:link>
        </rich:column>
    </rich:dataTable>

    </div>
    </rich:panel>

    <div class="tableControl">

        <s:link view="/InvDevolucionList.xhtml"
            rendered="#{invDevolucionList.previousExists}"
               value="#{messages.left}#{messages.left} First Page"
                  id="firstPage">
          <f:param name="firstResult" value="0"/>
        </s:link>

        <s:link view="/InvDevolucionList.xhtml"
            rendered="#{invDevolucionList.previousExists}"
               value="#{messages.left} Previous Page"
                  id="previousPage">
            <f:param name="firstResult"
                    value="#{invDevolucionList.previousFirstResult}"/>
        </s:link>

        <s:link view="/InvDevolucionList.xhtml"
            rendered="#{invDevolucionList.nextExists}"
               value="Next Page #{messages.right}"
                  id="nextPage">
            <f:param name="firstResult"
                    value="#{invDevolucionList.nextFirstResult}"/>
        </s:link>

        <s:link view="/InvDevolucionList.xhtml"
            rendered="#{invDevolucionList.nextExists}"
               value="Last Page #{messages.right}#{messages.right}"
                  id="lastPage">
            <f:param name="firstResult"
                    value="#{invDevolucionList.lastFirstResult}"/>
        </s:link>

    </div>

    <s:div styleClass="actionButtons" rendered="#{empty from}">
        <s:button view="/InvDevolucionEdit.xhtml"
                    id="create"
           propagation="none"
                 value="Create invDevolucion">
            <f:param name="invDevolucionDevCodigo"/>
        </s:button>
    </s:div>

</ui:define>

</ui:composition>
